Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add networking UIO driver #137

Open
wants to merge 25 commits into
base: main
Choose a base branch
from
Open

Add networking UIO driver #137

wants to merge 25 commits into from

Conversation

dreamliner787-9
Copy link
Contributor

@dreamliner787-9 dreamliner787-9 commented Nov 4, 2024

Supersedes #136.

This PR adds:

  • Networking UIO driver to libvmm to allow creation of Ethernet driver VMs (maybe WiFi/Cellular in the future?)
  • A patched echo server example that uses an Ethernet driver VM.

The basic idea is:

  • The sDDF network control, data regions and notification from virtualisers are mapped into Linux userspace via UIO.
  • A promiscuous socket is opened to sniff all incoming frames. When a frame comes through from the socket, we enqueue the data into the appropriate sDDF queues and fault on a pre-determined address so the VMM can notify the RX virtualiser.
  • When a client wants to transmit data, we will get TX virt notifications via UIO, then we simply write the data out into the socket.

There is a design issue to be aware of: the driver VM needs to know how many network clients there are and map their TX data regions into Linux userspace due to lack of DMA.

TCP performance:
Requested_Throughput,Receive_Throughput,Send_Throughput,Packet_Size,Minimum_RTT,Average_RTT,Maximum_RTT,Stdev_RTT,Median_RTT,Idle_Cycles,Total_Cycles
1000000000,145529249,145506692,1460,56336,63790,71432,1489.88,63770,0,0,0

UDP performance:
Requested_Throughput,Receive_Throughput,Send_Throughput,Packet_Size,Minimum_RTT,Average_RTT,Maximum_RTT,Stdev_RTT,Median_RTT,Idle_Cycles,Total_Cycles
200000000,176977185,200000147,1472,6615,8719,10681,1077.98,9053,0,0,0

Note that this performance depends on an unmerged sDDF network queue library that has compiler barriers.

@dreamliner787-9 dreamliner787-9 marked this pull request as ready for review November 4, 2024 06:29
Signed-off-by: Bill Nguyen <[email protected]>
Signed-off-by: Bill Nguyen <[email protected]>
Signed-off-by: Bill Nguyen <[email protected]>
Signed-off-by: Bill Nguyen <[email protected]>
Signed-off-by: Bill Nguyen <[email protected]>
Signed-off-by: Bill Nguyen <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant